package zhanglinwei.cryptotools.autoconfigure;

import org.springframework.boot.context.properties.ConfigurationProperties;
import zhanglinwei.cryptotools.core.constant.CryptoToolsConstant;

@ConfigurationProperties(
        prefix = CryptoToolsConstant.PREFIX
)
public class CryptoToolsProperties {

    private boolean enable = true;
    private String algorithm = CryptoToolsConstant.DEFAULT_ALGORITHM;

    public boolean isEnable() {
        return enable;
    }

    public void setEnable(boolean enable) {
        this.enable = enable;
    }

    public String getAlgorithm() {
        return algorithm;
    }

    public void setAlgorithm(String algorithm) {
        this.algorithm = algorithm;
    }

    @Override
    public String toString() {
        return "CryptoToolsProperties(enable=" + this.enable + ", algorithm=" + this.algorithm + ")";
    };
}
